home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d19 / dframe21.arc / DFRAME.DOC next >
Encoding:
Text File  |  1991-03-22  |  58.3 KB  |  1,181 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.                                D O O R F R A M E
  17.                                   Version 2.1
  18.  
  19.                         A BBS Doors Development Library
  20.  
  21.                               Copyright (c) 1990
  22.                                 by Ted Freeman
  23.                              All rights reserved.
  24.  
  25.  
  26.                                Support board is:
  27.  
  28.                                MicroNet PCBoard
  29.                       Node1: 405-528-3175 1200-14.4K HST
  30.                       Node2: 405-528-8610 1200/2400  MNP/3
  31.                       Node3: 405-557-1103 1200-9600K ULTRA 
  32.  
  33.  
  34.  
  35. DOORFRAME v2.1 - Users Guide - Page i
  36.  
  37.  
  38.                                 C O N T E N T S
  39.                                =================
  40.  
  41.         Warranty ............................................ ii
  42.         Copyright notice .................................... ii
  43.         Distribution ........................................ ii
  44.         Description ......................................... ii
  45.         BOX ................................................. 1
  46.         CLRSCRN ............................................. 2
  47.         DE.LAY .............................................. 2
  48.         DELFILE ............................................. 2
  49.         DETECT.ANSI ......................................... 2
  50.         DIS.PLAY ............................................ 3
  51.         DRIVESPACE .......................................... 4
  52.         ENTER ............................................... 4
  53.         EXISTS .............................................. 4
  54.         EXIT.DOOR ........................................... 4
  55.         GETDRV .............................................. 4
  56.         GETEXECPATH ......................................... 4
  57.         GETKBD .............................................. 5
  58.         GETKBD1 ............................................. 5
  59.         GETSUB .............................................. 5
  60.         IN.PUT .............................................. 5
  61.         INITIALIZE .......................................... 6
  62.         LINES ............................................... 6
  63.         MAKE.BLT ............................................ 6
  64.         MAKE.BLT.CURRENT .................................... 7
  65.         MORE ................................................ 7
  66.         MUSIC ............................................... 7
  67.         NAMECASE ............................................ 7
  68.         OUT.PUT ............................................. 7
  69.         RINSTR .............................................. 7
  70.         SEND ................................................ 8
  71.         SETERROR ............................................ 8
  72.         SETKBD .............................................. 8
  73.         SHOW.BLT ............................................ 8
  74.         SUBEXIST ............................................ 8
  75.         COLOR TABLE ......................................... 9
  76.         CONFIGURATION FILE FORMAT ........................... 9
  77.         PCBOARD.SYS VARIABLES ............................... 10
  78.         USERS.SYS VARIABLES ................................. 12
  79.         DOOR.SYS VARIABLES .................................. 13
  80.         DORINFOx.DEF VARIABLES .............................. 15
  81.         CALLINFO.BBS VARIABLES .............................. 16
  82.         SFDOORS.DAT VARIABLES ............................... 17
  83.         CHAIN.TXT VARIABLES ................................. 19
  84.         MISCELLANEOUS NOTES ................................. 20
  85.  
  86.  
  87. DOORFRAME v2.1 - Users Guide - Page ii
  88.  
  89.  
  90.                                    Warranty
  91.  
  92.     This product is provided "as is" without warranty of any kind. The entire
  93.     risk as to the results and  performance of the program is assumed by you.
  94.     Futhermore, the  author does  not warrant, guarantee, or  make any  other
  95.     representations regarding  the use of,  or the  results of the use of the
  96.     program,  and you  rely on the  program and  results  solely at  your own
  97.     risk.  The author  cannot and  will not accept  responsibility for system
  98.     damage, loss of profit, or any other special, consequential or incidental 
  99.     damages  resulting  from  the  use  or  inability  to  use this  product.
  100.  
  101.                                    Copyright
  102.  
  103.     DOORFRAME  Copyright (c) 1990 by  Ted  Freeman  is being  distributed as
  104.     Shareware. Under this concept you may use the  SHAREWARE  (unregistered)
  105.     version for a reasonable period of  time for evaluation  after which you
  106.     must either register your copy or discontinue  usage.
  107.  
  108.  
  109.                                  Distribution
  110.  
  111.     You  are encouraged to distribute DOORFRAME provided that all files
  112.     contained in the archive are distributed in their original and
  113.     unmodified state.
  114.  
  115.                                   Description
  116.  
  117.     
  118.     DOORFRAME is a subroutine library for developing online BBS Doors for
  119.     systems that are compatible with PCBOARD.SYS, USERS.SYS, DOOR.SYS,
  120.     CALLINFO.BBS or DORINFOx.DEF for interfacing to the BBS. DoorFrame was
  121.     written for QUICKBASIC (tm) 4.5 and is not recommended for use with
  122.     earlier versions of the compiler. DoorFrame also utilizes some of the
  123.     routines contained in Tom Hanlin's PBClone library. The COM routines
  124.     are handled by the QBSerial I/O library.
  125.  
  126.  
  127. DOORFRAME v2.1 - Users Guide - Page 1
  128.  
  129.  
  130.                               DOORFRAME ROUTINES
  131.                              ====================
  132.  
  133. ------------------------------------------------------------------------------
  134. NOTE: 
  135. Since the subroutines are DECLAREd in DFRAME.INC (you DID $INCLUDE: it didn't 
  136. you?) you should not use the CALL statement. Type the name of the subroutine 
  137. and list it's parameters (if any) without the enclosing parentheses.
  138. For example:
  139.  
  140.  DIS.PLAY MSG$, FG%, BG%, BLINK%, BELL%, XPOS%, YPOS%, NL%, CENTER%, CAPS% 
  141.  
  142. The FUNCTIONs still require the enclosing parentheses.
  143. ------------------------------------------------------------------------------
  144.  
  145. SUBROUTINE: 
  146. BOX.IT (SROW%,SCOL%,EROW%,ECOL%,BTYPE%,BFG%,BBG%,FFG%,FBG%,FCHAR%,SHADOW%,TITLE$)
  147. PARAMETERS: SROW%    - ROW the box is to start at. Valid numbers are 1 - 22.
  148.                        Accepts an INTEGER number or variable.
  149.             SCOL%    - COLUMN the box is to start at. Valid numbers are 1 - 79.
  150.                        Accepts an INTEGER number or variable.
  151.             EROW%    - ROW the box is to end at. Valid numbers are 2 - 23.
  152.                        Accepts an INTEGER number or variable.
  153.             ECOL%    - COLUMN the box is to end at. Valid numbers are 2 - 80.
  154.                        Accepts an INTEGER number or variable.
  155.             BTYPE%   - Type of border. Accepts an INTEGER number or variable.
  156.                          0 = No border (spaces all the way around).
  157.                          1 = Single line all the way around.
  158.                          2 = Double line all the way around.
  159.                          3 = Double line on sides, single on top and bottom.
  160.                          4 = Single line on sides, double on top and bottom.
  161.             BFG%     - Foreground color of the border. (See color table)
  162.                        Accepts an INTEGER number or variable.
  163.             BBG%     - Background color of the border. (See color table)
  164.                        Accepts an INTEGER number or variable.
  165.             FFG%     - Foreground color of the box fill characters.
  166.                        Accepts an INTEGER number or variable.
  167.             FBG%     - Background color of the box fill characters.
  168.                        Accepts an INTEGER number or variable.
  169.             FCHAR%   - ASCII number of the character to fill box with.
  170.                        EX: 32 = SPACE, 65 = A, 206 = ╬
  171.             SHADOW%  - 1 = Shadow, 0 = no Shadow. This will put a Shadow
  172.                        on the right and bottom edges of the box.
  173.             TITLE$   - Displays a title centered on the top border.
  174.                        Accepts a STRING variable or QUOTED TEXT.
  175.  
  176. DESCRIPTION: Draws a BOX with various style borders. The inside of the
  177.              BOX may be filled with any ASCII character you choose. The
  178.              upper left corner of the screen is ROW 1, COLUMN 1 and the
  179.              bottom right is ROW 23, COLUMN 80.
  180.  
  181.  
  182.  
  183. DOORFRAME v2.1 - Users Guide - Page 2
  184.  
  185.  
  186. SUBROUTINE: CLRSCRN
  187. PARAMETERS: None
  188. DESCRIPTION: Clears both the LOCAL (if ON) and REMOTE displays. This is the
  189.              only way you should do a clear screen.
  190.  
  191.  
  192. SUBROUTINE: DE.LAY (SEC%)
  193. PARAMETERS: SEC%, 1, 2, Etc.
  194. DESCRIPTION: Pauses your program for the number of seconds in SEC%. Accepts
  195.              INTEGER number or variable.
  196.  
  197. SUBROUTINE: DELFILE (FILENAME$, ERRCODE%)
  198. PARAMETERS: FILENAME$, "FILENAME"
  199. DESCRIPTION: Deletes the specified FILENAME$. Accepts a STRING in either
  200.              variable or quoted form. Full path specifications are supported.
  201.  
  202.  
  203. SUBROUTINE: DETECT.ANSI
  204. PARAMETERS: None
  205. DESCRIPTION: This routine will determine if the remote system has ANSI
  206.              capability. If the remote system is ANSI compatible, the
  207.              GRAPHICS% variable will be set equal to -1 otherwise it is
  208.              set to 0. This routine does not control whether COLOR is used
  209.              or not, see the MODE% variable for that.
  210.  
  211.  
  212.  
  213. DOORFRAME v2.1 - Users Guide - Page 3
  214.  
  215. SUBROUTINE: DIS.PLAY (MSG$,FG%,BG%,BLINK%,BELL%,XPOS%,YPOS%,NL%,CENTER%,CAPS%)
  216. PARAMETERS: MSG$     - Text to be printed in either variable or quoted form.
  217.                        Example: "Print this" or MSG$ = "Print this".
  218.  
  219.             FG%      - Foreground color (0 - 15) Of the text. Can be in
  220.                        INTEGER number or INTEGER variable form. 
  221.                        Example: FG% = 1, 1, BLUE (See Color Table)
  222.  
  223.             BG%      - Background color (0 - 7) of text otherwise same as FG%
  224.  
  225.             BLINK%   - Enter 1 for blinking text or 0 for normal text.
  226.                        Accepts INTEGER number or INTEGER variable.
  227.  
  228.             BELL%    - Enter 1 to sound a beep on the remote or 0 for no
  229.                        beep. Does not beep on the local computer.
  230.                        Accepts INTEGER number or INTEGER variable.
  231.  
  232.             XPOS%    - Row number for cursor positioning. Valid numbers
  233.                        are 0 - 23 (status line is on 24 - 25). Enter 0 to
  234.                        disable. Accepts INTEGER number or variable.
  235.                        NOTE: XPOS% is ignored when GRAPHICS% = 0.
  236.  
  237.             YPOS%    - Column number for cursor positioning. Valid numbers
  238.                        are 0 - 80. Enter 0 to disable. Accepts INTEGER number
  239.                        or INTEGER variable.
  240.                        NOTE: YPOS% is ignored when GRAPHICS% = 0.
  241.  
  242.             NL%      - Enter 1 to send a CR/LF at the end of the line. Enter
  243.                        0 to position the cursor after the last character.
  244.                        Accepts INTEGER number or INTEGER variable.
  245.  
  246.             CENTER%  - Enter 1 to center the line or 0 for no centering.
  247.  
  248.             CAPS%    - Enter 1 to convert text to all uppercase.
  249.                        Enter -1 to convert text to all lowercase.
  250.                        Enter 0 for no case conversion.
  251.                        Accepts INTEGER number or INTEGER variable.
  252.  
  253. DESCRIPTION: Displays text to both the Local (if on) and Remote screens.
  254.              Accepts the full ASCII charcter set (0 - 255). Supports ANSI
  255.              color and cursor positioning (XPOS%, YPOS%). DoorFrame features
  256.              auto-ANSI detection and will display in graphics mode if it
  257.              senses ANSI capability on the remote end.
  258.  
  259. ENHANCEMENTS: There are some special symbols available to make text blink
  260.              in the middle of a line in any color you wish. For example:
  261.  
  262.              DIS.PLAY "This will {Blink Yellow{", LWHITE, BLACK, 1, 0,......
  263.  
  264.              Note the {'s before and after Blink Yellow. They tell the routine
  265.              to display the text in between in yellow and blinks because 
  266.              BLINK% = 1. If BLINK% = 0 then the text is displayed in yellow
  267.              but does not blink. The rest of the line is displayed in white
  268.              on black. The symbols and their corresponding colors are:
  269.  
  270.               ~ = Blue,  ` = Green,  @ = Cyan,  ^ = Red,  | = Magenta
  271.               { = Yellow and } = White.
  272.  
  273.              Please note that you must have called DETECT.ANSI before using
  274.              these symbols and you may use only one set per DIS.PLAY. See the
  275.              included DISPLAY.BAS file for examples on using this option.
  276.  
  277.  
  278. DOORFRAME v2.1 - Users Guide - Page 4
  279.  
  280. FUNCTION:   DRIVESPACE (DRIVE$)
  281. PARAMETERS: DRIVE$, "C"
  282. DESCRIPTION: Returns number of free bytes on the specified drive (or -1 if
  283.              there was a disk error).
  284.                For example: BytesFree& = DRIVESPACE ("C").
  285.  
  286.  
  287. SUBROUTINE: ENTER
  288. PARAMETERS: None
  289. DESCRIPTION: Outputs a "Press <ENTER> to Continue" prompt and waits for the
  290.              response. If the caller is in graphics mode, this is centered
  291.              on line 23. In non-graphics mode it is centered 2 lines below
  292.              the last line printed.
  293.  
  294.  
  295. FUNCTION: EXISTS (FILENAME$ + CHR$(0))
  296. PARAMETERS: ASCIIZ Filename
  297. DESCRIPTION: Checks to see if a file exists on disk. The passed parameter
  298.              MUST be an ASCIIZ filename (FILENAME$ + CHR$(0)). The function
  299.              returns 0 if the file exists or -1 if it does not.
  300.              Example: IF EXISTS (MYFILE$ + CHR$(0)) = 0 THEN
  301.                          PRINT "The file is there!"
  302.                       ELSE
  303.                          PRINT "File not found."
  304.                       END IF
  305.  
  306.  
  307. SUBROUTINE: EXIT.DOOR (YN$)
  308. PARAMETERS: YN$, "Y", "N", "G"
  309. DESCRIPTION: VERY IMPORTANT! Always call this subroutine as the last thing
  310.              your program does. EXIT.DOOR updates the system files with any
  311.              changes that have been made to system variables, closes the
  312.              files, etc. When your Door closes, DoorFrame displays:
  313.  
  314.                         Thank you for using (Door Name)
  315.  
  316.                      Please wait while (BBS NAME) reloads.
  317.  
  318.              You can toggle this ON, "Y" or OFF, "N" when you call EXIT.DOOR.
  319.              Accepts a STRING variable YN$ = "Y" or quoted text "Y".
  320. PCBoard only: If you wish to allow the caller to log off from your Door, call
  321.               EXIT.DOOR "G". The PCBOARD% variable will tell you if the
  322.               system is a PCBoard. If PCBOARD% = 0 then this won't work.
  323.  
  324. SUBROUTINE: GETDRV (DRIVE$)
  325. PARAMETERS: DRIVE$
  326. DESCRIPTION: Returns the current default drive. You must initialize the
  327.              parameter to at least one character. For example:
  328.                 DRIVE$ = " "  or DRIVE$ ="x"
  329.                 GETDRV DRIVE$
  330.              After the call, DRIVE$ will contain the default drive letter.
  331.  
  332. SUBROUTINE: GETEXECPATH (PATHNAME$, PATHLEN%)
  333. PARAMETERS: PATHNAME$, PATHLEN%
  334. DESCRIPTION: Returns the full path of your program (drive, subdirectory and
  335.              name of program). PATHNAME$ must be initialized to at least 80
  336.              characters. The length of the PATH spec. is returned in the
  337.              variable PATHLEN%. Example:
  338.                 PATHNAME$ = SPACE$(80)
  339.                 GETEXECPATH PATHNAME$, PATHLEN%
  340.                 PATHNAME$ = LEFT$(PATHNAME$, PATHLEN%)
  341.  
  342.  
  343. DOORFRAME v2.1 - Users Guide - Page 5
  344.  
  345. SUBROUTINE: GETKBD (INSERT%, CAPS%, NUMLOCK%, SCRLOCK%)
  346. PARAMETERS: NONE
  347. DESCRIPTION: Returns the state of the 4 keyboard toggles: Insert, Caps Lock,
  348.              Num Lock, and Scroll Lock. Each of the variables above will be
  349.              populated with a zero (0) if the key is toggled OFF. They will
  350.              be non-zero if they are toggled ON.
  351.  
  352. SUBROUTINE: GETKBD1 (LSHIFT%, RSHIFT%, CONTROL%, ALT%)
  353. PARAMETERS: NONE
  354. DESCRIPTION: Returns the state of the 4 keyboard shift keys: Left Shift,
  355.              Right Shift, Control and ALT. Each of the variables above will
  356.              be populated with a non-zero number if the key is currently
  357.              being pressed, zero if not.
  358.  
  359. SUBROUTINE: GETSUB1 (DRIVE$, SUBDIR$, SUBLEN%, ERRCODE%)
  360. PARAMETERS: DRIVE$
  361. DESCRIPTION: Returns the current subdirectory on the specified drive. You
  362.              must initalize SUBDIR$ to at least 65 characters. Example:
  363.                 SUBDIR$ = SPACE$(65)
  364.                 GETSUB1 "C", SUBDIR$, SUBLEN%, ERRCODE%
  365.                 SUBDIR$ = LEFT$(SUBDIR$, SUBLEN%)
  366.  
  367.              SUBDIR$ returns with the subdirectory (padded with spaces).
  368.              SUBLEN% will contain the length of the subdirectory path and
  369.              ERRCODE% will 0 if there was no error or non-zero if there was.
  370.  
  371. SUBROUTINE: IN.PUT (LENGTH%, WAITTIME%, IFG%, IBG%)
  372. PARAMETERS: LENGTH%   - Desired length of input. Accepts an INTEGER number
  373.                         or variable. 0 = any length.
  374.             WAITTIME% - Number of seconds to wait for input. If ENTER is not
  375.                         pressed before this times out, control is passed back
  376.                         to the calling routine and RESPONSE$ will contain "-1"
  377.             IFG%      - Foreground color of the caller's response (INTEGER).
  378.             IBG%      - Background color of the caller's response (INTEGER).
  379.  
  380. DESCRIPTION: Gets a response from the caller which is returned in the variable
  381.              RESPONSE$. Passes ASCII characters in the range 32 - 127 and
  382.              ignores all others. The 1st parameter indicates the desired
  383.              length of the input. Pass 0 to accept any length. This feature
  384.              allows you to use HOT KEYS! If you are prompting for a Y/N you
  385.              could do something like:
  386.                 DIS.PLAY "Is everything correct? (y/n) " (+ your parameters)
  387.                 IN.PUT 1, 180, 12, 0
  388.                 IF UCASE$(RESPONSE$) = "Y" THEN
  389.                  Etc., Etc.
  390.              As soon as the caller hit Y or N, the subroutine terminates
  391.              without his having to hit ENTER (however IN.PUT always returns
  392.              when ENTER is pressed). Accepts an INTEGER number or variable.
  393.  
  394.              The IN.PUT can also be used as a timed routine. In the example
  395.              above, The routine would wait for 180 seconds. if it does not
  396.              receive a keypress within that time, it returns to the calling
  397.              routine and RESPONSE$ would contain a "-1".
  398.              (See the enclosed EXINPUT.BAS for an example).
  399.  
  400.  
  401. DOORFRAME v2.1 - Users Guide - Page 6
  402.  
  403.  
  404. SUBROUTINE: INITIALIZE
  405. PARAMETERS: None
  406. DESCRIPTION: VERY IMPORTANT! You MUST make a call to INITIALIZE before your
  407.              code does anything. This subroutine opens the system files and
  408.              obtains all the information you will need to run your Door. It
  409.              first reads the configuration file you passed on the command
  410.              line, then it reads PCBOARD.SYS, PCBOARD.DAT, and USERS (for 
  411.              PCBoard) or DOOR.SYS. There are 3 variables that must be
  412.              populated before the call to INITIALIZE. 
  413.                 PROGNAME$ = "Name of your Door"
  414.                 EXENAME$ = "FILENAM"
  415.                 VERSION$ = " v0.0"
  416.                 INITIALIZE
  417.              PROGNAME$ and VERSION$ are displayed on the Status line after
  418.              the callers name. EXENAME$ must be populated if you plan to use
  419.              the high score bulletin generator. EXENAME$ is the filename of
  420.              your program minus the .EXE extension.
  421.          ->  NOTE: EXENAME$ MUST BE NO MORE THAN 7 CHARACTERS!
  422.  
  423.  
  424. SUBROUTINE: LINES (SROW%,SCOL%,LEN%,DIR$,ENDS%,MID%,EFG%,EBG%,MFG%,MBG%)
  425. PARAMETERS: SROW%    - Row the line starts at. Valid numbers are 1 - 22.
  426.                        Accepts an INTEGER number or variable.
  427.             SCOL%    - Column the line starts at. Valid numbers are 1 - 79.
  428.                        Accepts an INTEGER number or variable.
  429.             LEN%     - Length of the line. Max. of 23 for vertical, 80 horiz.
  430.                        Accepts an INTEGER number or variable.
  431.             DIR$     - "H" = horizontal. "V" = vertical. Accepts a STRING
  432.                        variable or quoted text.
  433.             ENDS%    - If you are placing the line inside a box, you can
  434.                        make the ends of the line match the box border.
  435.                        Accepts an INTEGER number or variable.
  436.                          0 = No ends. (straight line only)
  437.                          1 = Single line.
  438.                          2 = Double line.
  439.             MID%     - Type of line. 1 = Single line. 2 = Double line.
  440.                        Accepts an INTEGER number or variable.
  441.             EFG%     - Foreground color of the ends (see color table).
  442.                        Accepts an INTEGER number or variable.
  443.             EBG%     - Background color of the ends (see color table).
  444.                        Accepts an INTEGER number or variable.
  445.             MFG%     - Foreground color of the line (see color table).
  446.                        Accepts an INTEGER number or variable.
  447.             MBG%     - Background color of the line (see color table).
  448.                        Accepts an INTEGER number or variable.
  449. DESCRIPTION: Draws either a vertical or horizontal line at the specified
  450.              location. 
  451.  
  452.  
  453. SUBROUTINE: MAKE.BLT (HI.SCORE#)
  454. PARAMETERS: HI.SCORE#, 10, 10000, Etc.
  455. DESCRIPTION: This routine will write a hi-score bulletin listing the top ten
  456.              scores. The parameter passed must be double precision (#). This
  457.              routine creates a file called FILENAME.BUL. The first line of
  458.              this .BUL file indicates the path to the actual BLT file. It
  459.              initially writes FILENAME.BLT. If you wish to have a different
  460.              filename (such as BLT1) you must edit this line. The filename
  461.              for your BLT file should be 7 characters or less because
  462.              DoorFrame also writes a graphics BLT and appends a G to the
  463.              filename. (You should also explain this to your user Sysops!)
  464.  
  465.  
  466.  
  467. DOORFRAME v2.1 - Users Guide - Page 7
  468.  
  469.  
  470. SUBROUTINE: MAKE.BLT.CURRENT (HI.SCORE#)
  471. PARAMETERS: HI.SCORE#, 10, 10000, Etc.
  472. DESCRIPTION: Same as MAKE.BLT except it posts CURRENT scores rather than
  473.              highest scores.
  474.  
  475.  
  476. SUBROUTINE: MORE
  477. PARAMETERS: None
  478. DESCRIPTION: Outputs "Press <ENTER> to continue, or <E> to end" and waits
  479.              for a response. Check the variable RESPONSE$ for an "E" and
  480.              terminate the current routine if found. For example:
  481.                 MORE
  482.                 IF UCASE$(RESPONSE$) = "E" THEN
  483.                   Etc.. Etc.
  484.  
  485.  
  486. SUBROUTINE: MUSIC (TUNE$)
  487. PARAMETERS: MUSIC CODES
  488. DESCRIPTION: Outputs music to the remote system. The TUNE$ parameter
  489.              contains the same codes you would normally use in the BASIC
  490.              PLAY statement. For example:
  491.               TUNE$ = "t110 l8 ms d4 mn o3 g a b o4 c ... "
  492.               MUSIC TUNE$
  493.              Since not all communications programs can handle music, you
  494.              should ask the user if he has music capabilities. If the
  495.              user can't handle music he will simply see the music codes
  496.              come across his screen (not a pretty sight!).
  497.  
  498.  
  499. SUBROUTINE: NAMECASE (ANAME$)
  500. PARAMETERS: ANAME$
  501. DESCRIPTION: Pass it a name in ANAME$ and it comes back with the first
  502.              letter in each word in upper case and the rest of the string
  503.              in lower case. Accepts a STRING variable only.
  504.  
  505.  
  506. SUBROUTINE: OUT.PUT (LF%)
  507. PARAMETERS: LF%, 1, 2, Etc.
  508. DESCRIPTION: Outputs the specified number of CR/LF. Parameter is an INTEGER
  509.              number or an INTEGER variable. Ex: OUT.PUT 2
  510.  
  511.  
  512. SUBROUTINE: RINSTR (MAINST$, SEEKST$, FOUND%)
  513. PARAMETERS: MAINST$, SEEKST$
  514. DESCRIPTION: Like INSTR, this routine tells your the position of a substring
  515.              within a string. A reverse search is used and tells you the
  516.              last match rather than the first match. Example:
  517.                 MAINST$ = "This is a test string"
  518.                 RINSTR MAINST$, "is", FOUND%
  519.              FOUND% will contain the position of the word "is" rather than
  520.              the last 2 letters of "This" as would be returned by INSTR.
  521.  
  522.  
  523.  
  524.  
  525. DOORFRAME v2.1 - Users Guide - Page 8
  526.  
  527.  
  528. SUBROUTINE: SEND (FILENAME$, YN%)
  529. PARAMETERS: FILENAME$ ofr "FILENAME".  YN%, 0, or 1 
  530.             FILENAME$ - STRING variable or quoted text of file to SEND.
  531.             YN%       - 0 = Do not use the ENTER prompt after last page.
  532.                         1 = Use the ENTER prompt after last page.
  533. DESCRIPTION: Sends the specified filename. This can be either an ASCII file
  534.              or an ANSI file. SEND first checks for the existance of the file
  535.              and either sends the file or reports "File not Found!". This is
  536.              handy for displaying Help files, Welcome screens, etc.
  537.  
  538.  
  539. SUBROUTINE: SETERROR (ERRORLEVEL%)
  540. PARAMETERS: ERRORLEVEL%, 1, 2, etc.
  541. DESCRIPTION: The SetError routine allows you to set the "error level" to be
  542.              returned by DOS when your program ends. This is very handy for
  543.              returning information to Batch files. Populate ErrorLevel% with
  544.              the exit code to be returned by your program.
  545.  
  546.  
  547. SUBROUTINE: SETKBD (INSERT%, CAPS%, NUMLOCK%, SCRLOCK%)
  548. PARAMETERS: INSERT%, CAP%, NUMLOCK%, SCRLOCK%, 0 or 1
  549. DESCRIPTION: Sets the state of any of the 4 keyboard toggles. 
  550.              0 = Toggled off
  551.              1 = Toggled on
  552.  
  553.  
  554. SUBROUTINE: SHOW.BLT (YN$)
  555. PARAMETERS: YN$, "Y", "N"
  556. DESCRIPTION: Call this routine if your Door features a Hi-score bulletin. Make
  557.              sure you have called MAKE.BLT first! Best place to call this
  558.              is just before you call EXIT.DOOR. For example:
  559.               MAKE.BLT HI.SCORE#
  560.               SHOW.BLT "Y"
  561.               EXIT.DOOR "Y"
  562.              SHOW.BLT "Y" will ask if they want to see the Bulletin.
  563.              SHOW.BLT "N" displays the bulletin without asking.
  564.  
  565.  
  566. SUBROUTINE: SUBEXIST (SUBDIR$, FOUND%)
  567. PARAMETERS: SUBDIR$, "C:\SUBDIR"
  568. DESCRIPTION: Tells you if a subdirectory actually exists. Pass a STRING
  569.              variable or quoted string. FOUND% will return with a zero if
  570.              the subdirectory doesn't exist or non-zero if it does.
  571.  
  572.  
  573. DOORFRAME v2.1 - Users Guide - Page 9
  574.  
  575.  
  576.                              C O L O R  T A B L E
  577.                             ======================
  578.  
  579. COLOR # - NAME       INTENSITY       FOREGROUND (FG%)     BACKGROUND (BG%)
  580. ---------------------------------------------------------------------
  581.  0 - BLACK              Low               X                   X
  582.  1 - BLUE                "                X                   X
  583.  2 - GREEN               "                X                   X
  584.  3 - CYAN                "                X                   X
  585.  4 - RED                 "                X                   X
  586.  5 - MAGENTA             "                X                   X
  587.  6 - YELLOW              "                X                   X
  588.  7 - WHITE               "                X                   X
  589.  8 - GRAY               High              X
  590.  9 - LBLUE               "                X
  591. 10 - LGREEN              "                X
  592. 11 - LCYAN               "                X
  593. 12 - LRED                "                X
  594. 13 - LMAGENTA            "                X
  595. 14 - LYELLOW             "                X
  596. 15 - LWHITE              "                X
  597.  
  598. The COLORs are defined as CONSTANT in the DFRAME.INC file so you may use
  599. either the actual color number, it's name or an INTEGER variable of your own
  600. choosing when CALLing the DIS.PLAY subroutine.
  601.  
  602.  
  603.  
  604. The first few lines of your Door should be:
  605.  
  606.    ' $INCLUDE: 'DFRAME.INC'
  607.    PROGNAME$ = "Name of the Door"
  608.    VERSION$ = " v1.0"
  609.    EXENAME$ = "FILENAM"           <- NOTE: Max of 7 letters!
  610.    TIMEOUT% = 240                 <- Numbers of seconds to wait for keyboard
  611.                                      activity. 240 will wait for 4 minutes
  612.                                      then send a Keyboard Timeout msg. and
  613.                                      exit back to the BBS.
  614.    OWNER$ = "Your Name"           <- For registered DoorFrame users only.
  615.    SERIAL$ = "99999"              <- DoorFrame will display an EVALUATION
  616.                                      COPY message until registered.
  617.    INITIALIZE
  618.    .
  619.    .
  620.    Your code.......
  621.    .
  622.    .
  623.    MAKE.BLT HI.SCORE#            <- If you want one generated.
  624.    SHOW.BLT                      <- If you want to show it before door closes.
  625.    EXIT.DOOR "Y"
  626.  
  627. The configuration filename passed on the command line is OPENed as #1. This
  628. file is left open so you may read additional lines from the .CNF file. 
  629. Although it is not absolutely necessary, you should CLOSE #1 somewhere near
  630. the start of your program.
  631.  
  632.  
  633.                               CONFIGURATION FILE
  634.                               ==================
  635.  
  636. The format of the configuration file used by Doors created with DoorFrame is:
  637.  
  638. C:\PCB\PCBOARD.SYS              <- For PCBoard systems using PCBOARD.SYS only
  639. C|\PCB\USERS.SYS                <- For PCBoard systems using USERS.SYS
  640. C:\BBS\CALLINFO.BBS             <- For Wildcat! systems.
  641. C:\BBS\DOOR.SYS                 <- For systems that support DOOR.SYS
  642. C:\BBS\DORINFOx.DEF             <- For QBBS/RBBS/RA. Replace x with Node #.
  643. C:\BBS\SFDOORS.DAT              <- For Spitfire systems.
  644. MicroNet                        <- BBS name
  645. Ted                             <- Sysop's first name
  646. Freeman                         <- Sysop's last name
  647.   .                             <- The Configuration file is left open as #1
  648.   .                                so you may add whatever is necessary.
  649.  
  650.  
  651.  
  652. DOORFRAME v2.1 - Users Guide - Page 10
  653.  
  654.  
  655.                   VARIABLES AVAILABLE WHEN USING PCBOARD.SYS
  656.                   ==========================================
  657.  
  658.         ALLOWEDBYTES#             Allowed D/L bytes from the PWRD file.
  659.                                   This number has already been multipled
  660.                                   by 1024 so it will be in actual bytes
  661.                                   rather than Kilobytes allowed.
  662.       * BAUDCONN$                 Connect rate of caller or "LOCAL"
  663.       * BAUDOPEN$                 Port opening BPS
  664.       * BBSSYS$                   Name of the BBS
  665.         CALLALARM%                Caller alarm status.     -1=ON, 0=OFF
  666.       * CALLERSLOC$               Location of CALLERSx log
  667.         CHATSTATUS$               Chat mode status. "U" or "A"
  668.       * CITY$                     Callers city and state
  669.       * CNAMESLOC$                Location of CNAMES
  670.       * COMPORT%                  COM port number
  671.         CONFREG$                  Conferences registered in
  672.         DISPLAY%                  Local display status.    -1=ON, 0=OFF
  673.         DOWNLOADS%                Number of downloads made
  674.       * ECC%                      Error corrected connect.  1=YES, 0=NO
  675.         EXENAME$                  Name of .EXE (Programmer supplied)
  676.         EXPERT$                   Expert mode - "Y" or "N"
  677.         EXPIRE$                   Callers expiration date
  678.       * FIRST$                    Callers first name
  679.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  680.                                   Determines if the caller is ANSI compatible
  681.                                   If your door requires the use of cursor
  682.                                   positioning and GRAPHICS% = 0 then you
  683.                                   should kick him back out of the door.
  684.       * HPHONE$                   Callers home phone number
  685.       * LASTON$                   Date caller last logged on (MM-DD-YY)
  686.         LEVEL&                    Callers security level
  687.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  688.       * LOGONHRS$                 Time caller logged on in HH:MM format
  689.       * LOGONMINS%                Time caller logged on in minutes
  690.         MODE%                     0 = Non-color, -1 = color is on. Default
  691.                                   is the BBS setting. You may force color
  692.                                   by setting this to -1.
  693.       * NAME$                     Callers full name
  694.       * NETWORK%                  1 = BBS is networked, 0 = no network
  695.       * NODENUM%                  Node number
  696.         OWNER$                    Name DoorFrame is registered to (if any).
  697.         PASSWORD$                 Password of caller
  698.         PAGEBELL%                 Page bell status.        -1=ON, 0=OFF
  699.         PAGELEN%                  Callers page length
  700.       * PCBDAT$                   Location of PCBOARD.DAT
  701.       * PCBOARD%                  1 = PCBoard, 0 = non-PCBoard
  702.         PRINTER%                  Printer status.          -1=ON, 0=OFF
  703.         PROGNAME$                 Name of DOOR (Programmer supplied)
  704.         RESPONSE$                 Returned after a CALL to IN.PUT
  705.         SERIAL$                   Your DoorFrame serial #. String variable.
  706.       * SYSLOC$                   Location of system file. This contains the
  707.                                   path/filename of line 1 in the .CFG file.
  708.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  709.       * SYSOPFIRST$               Sysops first name
  710.         SYSOPFLAG$                " ", "N"=Sysop Next, "X"=Exit to DOS
  711.       * SYSOPLAST$                Sysops last name
  712.       * SYSOPNAME$                Sysops first and last names
  713.  
  714.  
  715. DOORFRAME v2.1 - Users Guide - Page 11
  716.  
  717.  
  718.         TIMEADJUST%               Use to adjust the callers remaining time
  719.                                   online. This variable adjusts the ELAPSED
  720.                                   time so if you wish to decrease his time,
  721.                                   give this a positive value.
  722.       * TIMEALWD%                 Minutes caller is allowed
  723.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  724.                                   calculates this so changing it has no effect
  725.       * TIMENOW%                  Current time in minutes (0 - 1440)
  726.       * TIMESON%                  Number of times on system
  727.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  728.                                   not specified. Has a minimum of one min.
  729.                                   No limit on maximum. 
  730.       * TIMEUSED%                 Time used so far today in minutes
  731.         UPLOADS%                  Number of uploads made
  732.       * USERCOMMENT$              User maintained comment
  733.       * USERSLOC$                 Location of USERS file
  734.       * USERNUM%                  Record number of caller
  735.         VERSION$                  DOOR version # (Programmer supplied)
  736.       * WPHONE$                   Callers work phone number
  737.  
  738. NOTES: Variables marked with '*' are provided for information only.
  739.  
  740.  
  741. DOORFRAME v2.1 - Users Guide - Page 12
  742.  
  743.  
  744.                    VARIABLES AVAILABLE WHEN USING USERS.SYS
  745.                    ========================================
  746.  
  747.         When using USERS.SYS, all variables contained in PCBOARD.SYS may
  748.         be used plus the following additional variables.
  749.  
  750.         DAILYDNLDBYTES&          Bytes downloaded so far today.
  751.         DELETEFLAG%              1 = delete this record, 0 = keep
  752.         EXPIREDLEVEL&            Expired Security level
  753.         LASTCONF%                Conference number last in.
  754.         LASTTIMEON$              Last time caller was on
  755.         MSGS.LEFT%               Number of messages posted
  756.         MSGS.READ%               Number of messages read
  757.         PCB.VERSION%             PCBoard version number (i.e. 1450)
  758.         TOTDNLDBYTES&            Total number of BYTES downloaded
  759.         TOTUPLDBYTES&            Total number of BYTES uploaded
  760.  
  761. NOTES: These variables are all passed back to PCBoard.
  762.  
  763.  
  764. DOORFRAME v2.1 - Users Guide - Page 13
  765.  
  766.  
  767.                     VARIABLES AVAILABLE WHEN USING DOOR.SYS
  768.                     =======================================
  769.  
  770.         ALIAS$                    Callers alias/handle
  771.       * ANSISUPPORT$              Caller supports ANSI but in NG mode
  772.       * BAUDCONN$                 Connect rate of caller or "LOCAL"
  773.       * BAUDOPEN$                 Port opening BPS
  774.       * BBSCOLOR%                 BBS default color code (1-15)
  775.       * BBSSYS$                   Name of the BBS
  776.         BIRTHDATE$                Callers date of birth
  777.         CALLALARM%                Caller alarm status.     -1=ON, 0=OFF
  778.       * CITY$                     Callers city and state
  779.       * COMPORT%                  COM port number (1 - 4).
  780.         CONFREG$                  Conferences registered in
  781.         DAILY.BYTES.ALWD#         Daily download max. K limit
  782.         DISPLAY%                  Local display status.    -1=ON, 0=OFF
  783.         DOORS.OPENED%             Number of Doors caller has opened
  784.         DOWNLOADS%                Number of downloads made
  785.       * ECC%                      Error corrected connect.  1=YES, 0=NO
  786.         EXENAME$                  Name of .EXE (Programmer supplied)
  787.         EXFROM%                   Conference exited to Door from.
  788.         EXPERT$                   Expert mode - "Y" or "N"
  789.         EXPIRE$                   Callers expiration date
  790.       * EVENT$                    Event time (hh:mm)
  791.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  792.                                   Determines if the caller is ANSI compatible
  793.                                   If your door requires the use of cursor
  794.                                   positioning and GRAPHICS% = 0 then you
  795.                                   should kick him back out of the door.
  796.       * HPHONE$                   Callers home phone number
  797.       * LASTON$                   Date caller last logged on (MM-DD-YY)
  798.         LASTSCAN$                 Date of last directory/new files scan.
  799.         LEVEL&                    Callers security level
  800.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  801.       * LOGONHRS$                 Time caller logged on in HH:MM format
  802.       * LOGONMINS%                Time caller logged on in minutes
  803.         MAX.FILES%                Maximum daily files available
  804.         MINSCREDIT%               Time credits in minutes
  805.         MODE%                     0 = Non-color, -1 = color is on. Default
  806.                                   is the BBS setting. You may force color
  807.                                   by setting this to -1.
  808.         MSGS.LEFT%                Total messages left
  809.       * NAME$                     Callers full name
  810.       * NETWORK%                  1 = BBS is networked, 0 = no network
  811.       * NODENUM%                  Node number
  812.         NUM.DL.TODAY%             Files downloaded so far today
  813.         OWNER$                    Name DoorFrame is registered to (if any).
  814.         PAGEBELL%                 Page bell status.        -1=ON, 0=OFF
  815.         PAGELEN%                  Callers page length
  816.       * PARITY%                   Parity (word length?) (7 or 8)
  817.         PASSWORD$                 Password of caller
  818.       * PATHGEN$                  Path to the GEN directory
  819.       * PATHMAIN$                 Path to the MAIN directory
  820.         PRINTER%                  Printer status.          -1=ON, 0=OFF
  821.         PROGNAME$                 Name of DOOR (Programmer supplied)
  822.         PROTOCOL$                 Callers default protocol (Z, X, etc)
  823.         RESPONSE$                 Returned after a CALL to IN.PUT
  824.  
  825.  
  826. DOORFRAME v2.1 - Users Guide - Page 14
  827.  
  828.  
  829.         SECREM$                   Number of seconds remaining this call.
  830.         SERIAL$                   Your DoorFrame serial #. String variable.
  831.       * SYSLOC$                   Location of system file. This contains the
  832.                                   path/filename of line 1 in the .CFG file.
  833.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  834.       * SYSOPFIRST$               Sysops first name
  835.       * SYSOPLAST$                Sysops last name
  836.       * SYSOPNAME$                Sysops first and last names
  837.         TIMEADJUST%               Use to adjust the callers remaining time
  838.                                   online. This variable adjusts the ELAPSED
  839.                                   time so if you wish to decrease his time,
  840.                                   give this a positive value.
  841.       * TIMELASTCALL$             Time of last call (hh:mm)
  842.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  843.                                   calculates this so changing it has no effect
  844.       * TIMENOW%                  Current time in minutes (0 - 1440)
  845.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  846.                                   not specified. Has a minimum of one min.
  847.                                   No limit on maximum. 
  848.       * TIMESON%                  Number of times on system
  849.       * TIMEUSED%                 Time used so far today in minutes
  850.         TOTAL.BYTES.TODAY#        Daily download K total
  851.         TOTAL.KB.DL#              Total K bytes downloaded
  852.         TOTAL.KB.UL#              Total K bytes uploaded
  853.         UPLOADS%                  Number of uploads made
  854.       * USERCOMMENT$              User maintained comment
  855.       * USERNUM%                  Record number of caller
  856.         VERSION$                  DOOR version # (Programmer supplied)
  857.       * WPHONE$                   Callers work phone number
  858.  
  859. NOTES: Variables marked with '*' are provided for information only.
  860.  
  861.  
  862. DOORFRAME v2.1 - Users Guide - Page 15
  863.  
  864.  
  865.  
  866.                   VARIABLES AVAILABLE WHEN USING DORINFOx.DEF
  867.                   ===========================================
  868.  
  869.       * BAUDRATE$                 Baud rate and parity of caller.
  870.                                   Ex. 2400 BAUD,N,8,1
  871.                                   NOTE: RBBS adds baud rate of BBS.
  872.       * BBSSYS$                   Name of the BBS
  873.       * CITY$                     Callers city and state
  874.       * COMPORT%                  COM port number (1 - 4).
  875.         DISPLAY%                  Defaults to -1 (ON).
  876.       * DORINFO13TH$              13th line available only on RBBS systems.
  877.         EXENAME$                  Name of .EXE (Programmer supplied)
  878.       * FIRST$                    Callers first name
  879.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  880.                                   Determines if the caller is ANSI compatible
  881.                                   If your door requires the use of cursor
  882.                                   positioning and GRAPHICS% = 0 then you
  883.                                   should kick him back out of the door.
  884.                                   Use DETECT.ANSI to determine this.
  885.       * LAST$                     Callers last name
  886.       * LASTON$                   Default 01-01-80 (not provided in DORINFO)
  887.         LEVEL&                    Callers security level
  888.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  889.         MODE%                     0 = Non-color, -1 = color is on. Default
  890.                                   is the BBS setting. You may force color
  891.                                   by setting this to -1.
  892.       * NAME$                     Callers full name
  893.         NETWORK$                  Network type. DoorFrame reads/writes as is.
  894.       * NODENUM%                  Number of this Node.
  895.         OWNER$                    Name DoorFrame is registered to (if any).
  896.         PROGNAME$                 Name of DOOR (Programmer supplied)
  897.         RESPONSE$                 Returned after a CALL to IN.PUT
  898.         SERIAL$                   Your DoorFrame serial #. String variable.
  899.       * SYSLOC$                   Location of system file. This contains the
  900.                                   path/filename of line 1 in the .CFG file.
  901.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  902.       * SYSOPFIRST$               Sysops first name
  903.       * SYSOPLAST$                Sysops last name
  904.       * SYSOPNAME$                Sysops first and last names
  905.         TIMEADJUST%               Use to adjust the callers remaining time
  906.                                   online. This variable adjusts the ELAPSED
  907.                                   time so if you wish to decrease his time,
  908.                                   give this a positive value.
  909.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  910.                                   calculates this so changing it has no effect
  911.       * TIMENOW%                  Current time in minutes (0 - 1440)
  912.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  913.                                   not specified. Has a minimum of one min.
  914.                                   No limit on maximum. 
  915.       * TIMESON%                  Defaults to 1 (Not provided in DORINFO)
  916.       * TIMEUSED%                 Time used so far today in minutes
  917.  
  918. NOTES: Variables marked with '*' are provided for information only.
  919.  
  920.  
  921. DOORFRAME v2.1 - Users Guide - Page 16
  922.  
  923.  
  924.  
  925.                   VARIABLES AVAILABLE WHEN USING CALLINFO.BBS
  926.                   ===========================================
  927.  
  928.       * ALREADYCONNECTED$         "TRUE" or "FALSE"
  929.       * BAUDCONN$                 Connect rate of caller or "LOCAL"
  930.       * BBSSYS$                   Name of the BBS
  931.       * CITY$                     Callers city and state
  932.       * COMPORT%                  COM port number (1 - 4).
  933.         CONFREG$                  Conferences registered in (ABCD etc.)
  934.       * CONSOLE$                  "LOCAL" or "REMOTE"
  935.         DAILY.BYTES.ALWD#         Daily download max. K limit
  936.       * DATABITS$                 7 or 8
  937.         DISPLAY%                  Local display status.    -1=ON, 0=OFF
  938.       * DOORNUMBER$               BBS number of this door?
  939.         EXENAME$                  Name of .EXE (Programmer supplied)
  940.       * ENTERDOOR$                Time caller entered door in HH:MM format.
  941.       * FIRST$                    Callers first name
  942.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  943.                                   Determines if the caller is ANSI compatible
  944.                                   If your door requires the use of cursor
  945.                                   positioning and GRAPHICS% = 0 then you
  946.                                   should kick him back out of the door.
  947.                                   Use DETECT.ANSI to determine this.
  948.       * LAST$                     Callers last name
  949.         LASTMSG$                  Last message read
  950.       * LASTONDATE$               Date and time of last call
  951.         LEVEL&                    Callers security level
  952.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  953.       * LOGONDATETIME$            Time and date caller logged on to BBS
  954.       * LOGONHRS$                 Time caller logged on in HH:MM format
  955.         MODE%                     0 = Non-color, -1 = color is on. Default
  956.                                   is the BBS setting. You may force color
  957.                                   by setting this to -1.
  958.       * MNP$                      "MNP/ARQ Connection" or "Normal Connection"
  959.       * NAME$                     Callers full name
  960.         NUM.DL.TODAY%             Files downloaded so far today
  961.         OWNER$                    Name DoorFrame is registered to (if any).
  962.         PASSWORD$                 Password of caller
  963.         PROGNAME$                 Name of DOOR (Programmer supplied)
  964.         RESPONSE$                 Returned after a CALL to IN.PUT
  965.         SERIAL$                   Your DoorFrame serial #. String variable.
  966.       * SYSLOC$                   Location of system file. This contains the
  967.                                   path/filename of line 1 in the .CFG file.
  968.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  969.       * SYSOPFIRST$               Sysops first name
  970.       * SYSOPLAST$                Sysops last name
  971.       * SYSOPNAME$                Sysops first and last names
  972.         TIMEADJUST%               Use to adjust the callers remaining time
  973.                                   online. This variable adjusts the ELAPSED
  974.                                   time so if you wish to decrease his time,
  975.                                   give this a positive value.
  976.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  977.                                   calculates this so changing it has no effect
  978.       * TIMENOW%                  Current time in minutes (0 - 1440)
  979.       * TIMEOFF$                  Time caller exited from the door.
  980.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  981.                                   not specified. Has a minimum of one min.
  982.                                   No limit on maximum. 
  983.       * TIMEUSED%                 Time used so far today in minutes
  984.       * USERNUM%                  Record number of caller
  985.  
  986. NOTES: Variables marked with '*' are provided for information only.
  987.  
  988.  
  989. DOORFRAME v2.1 - Users Guide - Page 17
  990.  
  991.  
  992.  
  993.                   VARIABLES AVAILABLE WHEN USING SFDOORS.DAT
  994.                   ==========================================
  995.  
  996.         ANSION$                   "TRUE" or "FALSE"
  997.       * BAUDCONN$                 Connect rate of caller or "LOCAL"
  998.       * BBSDIR$                   Spitfire's home directory
  999.       * BBSSYS$                   Name of the BBS
  1000.       * CITY$                     Callers city and state
  1001.       * COMPORT%                  COM port number (1 - 4).
  1002.         DAILY.BYTES.ALLOWED#      Maximum download BYTES per day
  1003.         DISPLAY%                  Local display status.    -1=ON, 0=OFF
  1004.         DLPERDAY%                 Number of downloads allowed per day
  1005.         DLTODAY%                  Number of downloads made today
  1006.         DOWNLOADS%                Number of downloads made
  1007.       * ECC%                      Error corrected connect.  1=YES, 0=NO
  1008.         EXENAME$                  Name of .EXE (Programmer supplied)
  1009.         EXTRATIME&                Number of seconds gained since logon
  1010.       * FIRST$                    Callers first name
  1011.       * FRONTEND$                 "TRUE" or "FALSE" if booted from a
  1012.                                   front end program.
  1013.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  1014.                                   Determines if the caller is ANSI compatible
  1015.                                   If your door requires the use of cursor
  1016.                                   positioning and GRAPHICS% = 0 then you
  1017.                                   should kick him back out of the door.
  1018.                                   Use DETECT.ANSI to determine this.
  1019.       * HPHONE$                   Callers home phone number
  1020.       * LAST$                     Callers last name
  1021.         LASTMCONF$                Last message conference
  1022.         LASTFAREA$                Last file area
  1023.         LEVEL&                    Callers security level
  1024.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  1025.       * LOGONHRS$                 Time caller logged on in HH:MM format
  1026.       * LOGONSECS&                Number of seconds since midnight
  1027.                                   when caller logged on to the BBS.
  1028.       * MAXBAUD$                  Maximum baud of the system
  1029.         MODE%                     0 = Non-color, -1 = color is on. Default
  1030.                                   is the BBS setting. You may force color
  1031.                                   by setting this to -1.
  1032.       * NAME$                     Callers full name
  1033.       * NODENUM%                  Number of this Node.
  1034.       * NODTELOCK$                "TRUE" or "FALSE" if configured for
  1035.                                   software data flow control.
  1036.         OWNER$                    Name DoorFrame is registered to (if any).
  1037.         PASSWORD$                 Password of caller
  1038.         PROGNAME$                 Name of DOOR (Programmer supplied)
  1039.         RESPONSE$                 Returned after a CALL to IN.PUT
  1040.       * SECONDS&                  Number of seconds since midnight
  1041.                                   when caller entered the door.
  1042.         SERIAL$                   Your DoorFrame serial #. String variable.
  1043.       * SYSLOC$                   Location of system file. This contains the
  1044.                                   path/filename of line 1 in the .CFG file.
  1045.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  1046.       * SYSOPFIRST$               Sysops first name
  1047.       * SYSOPLAST$                Sysops last name
  1048.       * SYSOPNAME$                Sysops first and last names
  1049.         SYSOPNEXT$                "TRUE" or "FALSE"
  1050.  
  1051. NOTES: Variables marked with '*' are provided for information only.
  1052.  
  1053.  
  1054. DOORFRAME v2.1 - Users Guide - Page 18
  1055.  
  1056.  
  1057.         TIMEADJUST%               Use to adjust the callers remaining time
  1058.                                   online. This variable adjusts the ELAPSED
  1059.                                   time so if you wish to decrease his time,
  1060.                                   give this a positive value.
  1061.       * TIMEALWD%                 Minutes caller is allowed
  1062.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  1063.                                   calculates this so changing it has no effect
  1064.       * TIMENOW%                  Current time in minutes (0 - 1440)
  1065.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  1066.                                   not specified. Has a minimum of one min.
  1067.                                   No limit on maximum. 
  1068.       * TIMEUSED%                 Time used so far today in minutes
  1069.  
  1070.         TOTAL.BYTES.TODAY#        BYTES downloaded so far today
  1071.         TOTAL.KB.DL#              Total K bytes downloaded
  1072.         TOTAL.KB.UL#              Total K bytes uploaded
  1073.         UPLOADS%                  Number of uploads made
  1074.       * USERNUM%                  Record number of caller
  1075.  
  1076. NOTES: Variables marked with '*' are provided for information only.
  1077.  
  1078.  
  1079. DOORFRAME v2.1 - Users Guide - Page 19
  1080.  
  1081.  
  1082.                    VARIABLES AVAILABLE WHEN USING CHAIN.TXT
  1083.                    ========================================
  1084.  
  1085.         AGE$                      Caller's age
  1086.         ALIAS$                    Callers alias/handle
  1087.       * BBSSYS$                   Name of the BBS
  1088.       * CALLSIGN$                 HAM radio call sign
  1089.         COLUMNS$                  Caller's screen width
  1090.       * COMPORT%                  COM port number (1 - 4).
  1091.         COSYSOP%                  1 if Caller is co-Sysop, 0 if not
  1092.       * DATADIR$                  System DATA directory
  1093.         DISPLAY%                  Local display status.    -1=ON, 0=OFF
  1094.         DOWNLOADS%                Number of downloads made
  1095.         EXENAME$                  Name of .EXE (Programmer supplied)
  1096.       * FIRST$                    Callers first name
  1097.       * GFILESDIR$                System GFILES directory
  1098.         GOLD$                     Caller's gold (?)
  1099.         GRAPHICS%                 Graphics mode status.    -1=ON, 0=OFF
  1100.                                   Determines if the caller is ANSI compatible
  1101.                                   Use DETECT.ANSI to determine this.
  1102.       * LAST$                     Callers last name
  1103.       * LASTON$                   Date caller last logged on (MM/DD/YY)
  1104.         LEVEL&                    Callers security level
  1105.       * LOCALUSR%                 -1 = LOCAL mode, 0 = Online
  1106.       * LOG$                      System LOG of the day
  1107.       * LOGONSECS&                Number of seconds since midnight
  1108.                                   when caller logged on to the BBS.
  1109.         MODE%                     0 = Non-color, -1 = color is on. Line 14
  1110.                                   of CHAIN.TXT determines this setting.
  1111.       * NAME$                     Callers full name
  1112.       * NODENUM%                  Defaults to 1 (not provided in CHAIN.TXT)
  1113.         OWNER$                    Name DoorFrame is registered to (if any).
  1114.         PAGELEN%                  Callers page length
  1115.         PARITY$                   "8N1" etc.
  1116.         PROGNAME$                 Name of DOOR (Programmer supplied)
  1117.         RESPONSE$                 Returned after a CALL to IN.PUT
  1118.         SERIAL$                   Your DoorFrame serial #. String variable.
  1119.         SEX$                      Callers sex
  1120.       * SYSLOC$                   Location of system file. This contains the
  1121.                                   path/filename of line 1 in the .CFG file.
  1122.       * SYSOP%                    1 = SYSOP is using DOOR, 0 otherwise
  1123.       * SYSOPFIRST$               Sysops first name
  1124.       * SYSOPLAST$                Sysops last name
  1125.       * SYSOPNAME$                Sysops first and last names
  1126.         TIMEADJUST%               Use to adjust the callers remaining time
  1127.                                   online. This variable adjusts the ELAPSED
  1128.                                   time so if you wish to decrease his time,
  1129.                                   give this a positive value.
  1130.       * TIMELEFT%                 Time caller has left in minutes. Doorframe
  1131.                                   calculates this so changing it has no effect
  1132.       * TIMENOW%                  Current time in minutes (0 - 1440)
  1133.         TIMEOUT%                  Programmer supplied. Defaults to 5 mins if
  1134.                                   not specified. Minimum 1 min. 
  1135.       * TIMEUSED%                 Time used so far today in minutes
  1136.         TOTAL.KB.DL#              Total K bytes downloaded
  1137.         TOTAL.KB.UL#              Total K bytes uploaded
  1138.         UPLOADS%                  Number of uploads made
  1139.       * USERNUM%                  Record number of caller
  1140.  
  1141. NOTES: Variables marked with '*' are provided for information only.
  1142.  
  1143.  
  1144. DOORFRAME v2.1 - Users Guide - Page 20
  1145.  
  1146.  
  1147.                                 MISCELLANEOUS NOTES
  1148.                                 ===================
  1149.  
  1150. DoorFrame requires DOS 3.x and up since all files are opened in SHARED mode.
  1151.  
  1152. When using PCBOARD.SYS, DoorFrame requires that PCBOARD.DAT be in the same
  1153. directory as PCBOARD.SYS. DoorFrame also accesses the USERS file.
  1154.  
  1155. When using USERS.SYS, DoorFrame also accesses PCBOARD.SYS, PCBOARD.DAT and the 
  1156. USERS file.
  1157.  
  1158. The DOOR.SYS used by DoorFrame is the standard 52 line GAP (tm) file.
  1159.  
  1160. The CALLINFO.BBS used by DoorFrame currently contains 36 lines.
  1161.  
  1162. Trapping errors
  1163. ---------------
  1164.  If you wish to utilize the internal error trapping, insert the following
  1165.  line wherever you wish the trapping to begin. I would suggest putting it
  1166.  right after you call INITIALIZE.
  1167.  
  1168.    ON ERROR GOTO ERR.ROUTINE
  1169.  
  1170.  Then at the very end of your program insert the following:
  1171.  
  1172.    ERR.ROUTINE:
  1173.    ERRORS ERR, ERL
  1174.    END
  1175.  
  1176.  If ANY Basic error is encountered, it will branch to ERR.ROUTINE and call
  1177.  the ERRORS subroutine. The error will be printed to the screen and written
  1178.  to DFRAME.ERR. Your Door will then exit back to the BBS.
  1179.  
  1180.  
  1181.